package com.lala.commom.remote;


import com.github.pagehelper.PageInfo;
import com.lala.commom.pojo.User;
import org.springframework.web.bind.annotation.RequestBody;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RequestParam;
import org.springframework.web.bind.annotation.ResponseBody;

import java.util.Date;

public interface UserRemote {
    @RequestMapping("/login")
    User selectLoginname(@RequestParam("loginName") String loginName);
    @RequestMapping("/zhuce")
    int zhuce (@RequestBody User user);

    @RequestMapping("/selectUser")
    PageInfo<User> selectUser(@RequestParam("pageNum") int pageNum, @RequestParam("pageSize") int pageSize);

    /*修改用户密码(学生)*/
    @RequestMapping("/updateUser")
    int updateUser(@RequestParam("id") Integer id);

    /*删除用户（学生）*/
    @RequestMapping("/deleteUser")
    int deleteUser(@RequestParam("id") Integer id);

    //买东西
    @RequestMapping("/maike")
    int maike(@RequestParam("id")int id ,@RequestParam("money")int money);
}
